<?php
	$obj=new Info();
	if ( strcasecmp( @ $_SERVER['REQUEST_METHOD'], 'POST' ) == 0 )
	{
		$list= array(
					"WebsiteName",
					"CompanyName",
					"DomainName",
					"Address",
					"Region",
					"Country",
					"Email1",
					"Email2",
					"Telephone1",
					"Telephone2",
					"Fax1",
					"Fax2"
					);
		foreach ($list as $key )
		{
			$obj->InfoID=$module.$key;
			$obj->InfoName=$_POST[$key];
			$obj->InfoNameEng=$_POST[$key.'Eng'];
			$obj->save($conn);
		}
		//linkto("?module=$module");	
	}
	$arr=$obj->getNameArr("");
	$arrEng=$obj->getNameArr("Eng");
?>
<form name="f" action="" method="post" enctype="multipart/form-data">
<div class="ContentTitle">
    <div class="left" style="padding-top:8px"><?php echo $objModule->ModuleName?></div>
    <div class="CMSButton right">
        <a onclick="f.submit()">Save</a>
        <a href="?module=<?php echo $module?>">Cancel</a>
    </div>    
    <div class="clear"></div>
</div>
<ul id="ContentTabs" class="shadetabs">
    <li><a id="linkTab1" onclick="ShowHideDiv('Tab',1,2,'link')" class="selected">Viet Nam</a></li>
    <li><a id="linkTab2" onclick="ShowHideDiv('Tab',2,2,'link')">English</a></li>
    
</ul>       

<div id="Tab1" class="TabContainer ngt_Product">
<!-------------CONTENT OF EACH MODULE ---------------------------->
<table width="100%">
	<tr>
		<td>T&#234;n website:</td>
		<td>
			<input type="text" name="WebsiteName" value="<?php echo $arr['websettingWebsiteName']?>"/>
		</td>
	</tr>
	<tr>
		<td>T&#234;n c&#244;ng ty: </td>
		<td>
			<input type="text" name="CompanyName" value="<?php echo $arr['websettingCompanyName']?>"/>
		</td>
	</tr>
    <tr>
		<td>T&#234;n mi&#7873;n: </td>
		<td>
			<input type="text" name="DomainName" value="<?php echo $arr['websettingDomainName']?>"/>
		</td>
	</tr>
    <tr>
		<td>&#272;&#7883;a ch&#7881;: </td>
		<td>
            <textarea name="Address"><?php echo $arr['websettingAddress']?></textarea>
		</td>
	</tr>
    <tr>
		<td>V&#249;ng: </td>
		<td>
			<input type="text" name="Region" value="<?php echo $arr['websettingRegion']?>"/>
		</td>
	</tr>
    <tr>
		<td>Qu&#7889;c gia: </td>
		<td>
			<input type="text" name="Country" value="<?php echo $arr['websettingCountry']?>"/>
		</td>
	</tr>
    <tr>
		<td>Email1: </td>
		<td>
			<input type="text" name="Email1" value="<?php echo $arr['websettingEmail1']?>"/>
		</td>
	</tr>
    <tr>
		<td>Email2: </td>
		<td>
			<input type="text" name="Email2" value="<?php echo $arr['websettingEmail2']?>"/>
		</td>
	</tr>
    <tr>
		<td>&#272;i&#7879;n tho&#7841;i 1: </td>
		<td>
			<input type="text" name="Telephone1" value="<?php echo $arr['websettingTelephone1']?>"/>
		</td>
	</tr>
    <tr>
		<td>&#272;i&#7879;n tho&#7841;i 2: </td>
		<td>
			<input type="text" name="Telephone2" value="<?php echo $arr['websettingTelephone2']?>"/>
		</td>
	</tr>
    <tr>
		<td>Fax 1: </td>
		<td>
			<input type="text" name="Fax1" value="<?php echo $arr['websettingFax1']?>"/>
		</td>
	</tr>
    <tr>
		<td>Fax 2: </td>
		<td>
			<input type="text" name="Fax2" value="<?php echo $arr['websettingFax2']?>"/>
		</td>
	</tr>
</table>
<!-------------END CONTENT OF EACH MODULE ---------------------------->
</div>
<div id="Tab2" class="TabContainer ngt_Product" style="display:none">
<table width="100%">
	<tr>
		<td>Website name:</td>
		<td>
			<input type="text" name="WebsiteNameEng" value="<?php echo $arrEng['websettingWebsiteName']?>"/>
		</td>
	</tr>
	<tr>
		<td>Website Owner: </td>
		<td>
			<input type="text" name="CompanyNameEng" value="<?php echo $arrEng['websettingCompanyName']?>"/>
		</td>
	</tr>
    <tr>
		<td>Domain name: </td>
		<td>
			<input type="text" name="DomainNameEng" value="<?php echo $arrEng['websettingDomainName']?>"/>
		</td>
	</tr>
    <tr>
		<td>Address: </td>
		<td>
			<textarea name="AddressEng"><?php echo $arrEng['websettingAddress']?></textarea>
		</td>
	</tr>
    <tr>
		<td>Region: </td>
		<td>
			<input type="text" name="RegionEng" value="<?php echo $arrEng['websettingRegion']?>"/>
		</td>
	</tr>
    <tr>
		<td>Country: </td>
		<td>
			<input type="text" name="CountryEng" value="<?php echo $arrEng['websettingCountry']?>"/>
		</td>
	</tr>
    <tr>
		<td>Email1: </td>
		<td>
			<input type="text" name="Email1Eng" value="<?php echo $arrEng['websettingEmail1']?>"/>
		</td>
	</tr>
    <tr>
		<td>Email2: </td>
		<td>
			<input type="text" name="Email2Eng" value="<?php echo $arrEng['websettingEmail2']?>"/>
		</td>
	</tr>
    <tr>
		<td>Telephone 1: </td>
		<td>
			<input type="text" name="Telephone1Eng" value="<?php echo $arrEng['websettingTelephone1']?>"/>
		</td>
	</tr>
    <tr>
		<td>Telephone 2: </td>
		<td>
			<input type="text" name="Telephone2Eng" value="<?php echo $arrEng['websettingTelephone2']?>"/>
		</td>
	</tr>
    <tr>
		<td>Fax 1: </td>
		<td>
			<input type="text" name="Fax1Eng" value="<?php echo $arrEng['websettingFax1']?>"/>
		</td>
	</tr>
    <tr>
		<td>Fax 2: </td>
		<td>
			<input type="text" name="Fax2Eng" value="<?php echo $arrEng['websettingFax2']?>"/>
		</td>
	</tr>
</table>
</div>

</form>